﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<NETMovie.UI.WebMVC.Models.MovieModel>" %>
<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	MovieAdd
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Edit Movie</h2>

    <% using (Html.BeginForm()) { %>
        <%: Html.ValidationSummary(true, "Movie creation was unsuccessful. Please correct the errors and try again.") %>
        <div>
            <fieldset>
                <legend>Movie Information</legend>
                 <%: Html.HiddenFor(m => m.MovieId) %>
                <div class="editor-label">
                    <%: Html.LabelFor(m => m.Title) %>
                </div>
                <div class="editor-field">
                    <%: Html.TextBoxFor(m => m.Title)%>
                    <%: Html.ValidationMessageFor(m => m.Title)%>
                </div>
                 <div class="editor-label">
                    <%: Html.LabelFor(m => m.Summary) %>
                </div>
                <div class="editor-field">
                    <%: Html.TextBoxFor(m => m.Summary)%>
                    <%: Html.ValidationMessageFor(m => m.Summary)%>
                </div>
                <div class="editor-label">
                    <%: Html.LabelFor(m => m.Description)%>
                </div>
                  <div class="editor-field">
                    <%: Html.TextBoxFor(m => m.Description)%>
                    <%: Html.ValidationMessageFor(m => m.Description)%>
                </div>
                 <div class="editor-label">
                    <%: Html.LabelFor(m => m.ArticleUrl)%>
                </div>
                  <div class="editor-field">
                    <%: Html.TextBoxFor(m => m.ArticleUrl)%>
                    <%: Html.ValidationMessageFor(m => m.ArticleUrl)%>
                </div>
                  <div class="editor-field">
                    <%: Html.DropDownListFor(m => m.Category,(IEnumerable<SelectListItem>)Session["CategoryList"])%>
                    <%: Html.ValidationMessageFor(m => m.Categories)%>
                </div>
      
                <div class="editor-label">
                    <%: Html.LabelFor(m => m.isPremium)%>
                </div>
                  <div class="editor-field">
                    <%: Html.RadioButtonFor(m => m.isPremium, "true")%> Yes
                        <%: Html.RadioButtonFor(m => m.isPremium, "false")%> No
                </div>
                <div class="editor-label">
                    <%: Html.LabelFor(m => m.AvailableDate)%>
                </div>
                  <div class="editor-field">
                    <%: Html.TextBoxFor(m => m.AvailableDate)%>
                  <%: Html.ValidationMessageFor(m => m.AvailableDate)%>
                </div>
                    <div class="editor-label">
                    <%: Html.LabelFor(m => m.ReleaseDate)%>
                </div>
                  <div class="editor-field">
                    <%: Html.TextBoxFor(m => m.ReleaseDate)%>
                  <%: Html.ValidationMessageFor(m => m.ReleaseDate)%>
                </div>
                
                <p>
                    <input type="submit" value="Edit Movie" />
                </p>
            </fieldset>
        </div>
    <% } %>
</asp:Content>
